<?php
set_include_path(dirname(__FILE__) . PATH_SEPARATOR . get_include_path());
require_once 'Junction/Libs/Bootstrap.php';

require_once 'Junction/Core/Session.php';
require_once 'Junction/Utils/Config.php';

class Junction {
    
	/**
	 * Construct a new Junction session.
	 * 
	 * @throws Junction_Core_Exception
	 *
	 * @return Junction_Core_Session
	 */
	public static function construct() {
		return new Junction_Core_Session();
	}
	
	/**
	 * Modify the path to Junction's configuration.
	 * 
	 * <p>The new path can be a relative or absolute path.  Any
	 * relative paths must be reachable via the include path.
	 * Note that Junction adds itself to the include path, so
	 * the config can be within Junction itself.
	 * 
	 * <p>The config file itself should be titled Junction.ini.
	 * The path should be to the directory containing this file.
	 *
	 * @param String $path a valid path to a directory.
	 */
	public static function setConfiguration($path) {
	    Junction_Utils_Config::setPath($path);
	}
}
?>